/*
/!**
 * Created by WLG on 2018/11/27.
 *!/
let uuid = require('uuid');
console.log(uuid.v1());*/

function testCrypto(){
    let cryptoUtil = require('./lib/cryptoUtil');

    let aArray = ["Bbc","ABC","ABc","Abc","AbC","BBC"];

    console.log(cryptoUtil.createSha1(aArray.sort().join('-')));

    aArray.push("DSawefawefawefaefefereaaaaaaaaaaaaaawegvwvbfdfntrtryteuuwqtytiyod");
    aArray.push("DSawefawefawefaefeferebbbbbbbbbbbbbawegvwvbfdfntrtryteuuwqtytiyod");
    aArray.push("DSawecccccccccccccfawefawefaefefereawegvwvbfdfntrtryteuuwqtytiyod");
    aArray.push("dDSawefadddwefawefaedfefereawegvwvdbfdfntrzzzvbbtryteuuwqtydtiyod");
    aArray.push("DSawefawefawefaefefereawegvwvbfdfntrtrytedscczzzzudduwqty08ftiyod");

    console.log(cryptoUtil.createSha1(aArray.sort().join('-')));
}
function testEncode(){
    let iconv = require( 'iconv-lite');

    let text = '你';

    let encodedBuff = iconv.encode(text, 'utf-8');
    console.log("filename="+encodedBuff);

}
function testContentDsposition(){
    let name = encodeURI("文件.txt", "utf-8");
    console.log("attachment; filename* = UTF-8''"+name);
}

function main(){
    testContentDsposition();
}

main();
